<?php
/**
 * 微信菜单接口
 */
namespace app\common\service\wechat;
class WeChatMenu extends WeChatService {
	/**
	 * wechat操作句柄
	 * @var object | \WeChat\Qrcode
	 */
	private $handle;
	
	/**
	 * 初始化方法
	 * {@inheritDoc}
	 * @see WeChatService::__init()
	 */
	public function __init() {
		$this->handle = new \WeChat\Menu(self::$option);
	}
	
	/**
	 * 获取菜单列表
	 * @return [type] [description]
	 */
	public function  getMenus(){
		return $this->handle->get();
	}


    /**
     * 创建菜单
     * @param string $data
     * @return array
     */
	public  function createMenu( $data = "" ){
		return $this->handle->create( $data );
	}
	
}